import 'package:flutter/material.dart';
import 'package:get/get.dart';
import 'package:xindong/common/xindong_sezhi.dart';
import 'package:xindong/routes/call/controller/xindong_call_timer_ctr.dart';

// 通话时长
class XinDongCallTimerView extends StatelessWidget {
  const XinDongCallTimerView({Key? key}) : super(key: key);

  @override
  Widget build(BuildContext context) {
    return Container(
      alignment: Alignment.centerLeft,
      padding: const EdgeInsets.only(left: 16.0),
      child: Column(
        mainAxisSize: MainAxisSize.min,
        mainAxisAlignment: MainAxisAlignment.start,
        crossAxisAlignment: CrossAxisAlignment.start,
        children: [
          Container(
            height: 28,
            padding: const EdgeInsets.only(left: 10, right: 10),
            decoration: BoxDecoration(
              borderRadius: BorderRadius.circular(28),
              color: DZColors.transparentButtonColor,
            ),
            child: GetBuilder<XinDongCallTimerController>(
                builder: (controller) {
                return Row(
                  mainAxisSize: MainAxisSize.min,
                  crossAxisAlignment: CrossAxisAlignment.center,
                  children: [
                    Text(
                      "通话时长：${controller.showCallTime}",
                      style: const TextStyle(color: Colors.white, fontSize: 12, height: 1.2),
                    ),
                  ],
                );
              }
            ),
          ),
          // Opacity(opacity: 0.68, child: TaoQiGroupChatNetworkWidget()),
        ],
      ),
    );
  }
}
